!
<!DOCTYPE html>
<html>

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title></title>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.4.1/css/bootstrap.css" rel="stylesheet">
</head>

<body>
    <div id='app'>
        <sin @father="but"></sin>
    </div>

    <template id="demo">
        <div>
            <!-- <button type="button" class="btn btn-primary">原始按钮</button> -->
           <button @click="chage">子组件</button>
        </div>
    </template>
    <script>

        Vue.component("sin", {
            template: "#demo",
            methods:{
                chage(){
                    this.$emit("father","我是子组件给父组件传值")
                }
            }
            
            
        })

        const vm = new Vue({
            el: '#app',
            data: {
               
            },
            methods:{
                but(date1){
                    console.log(date1);
                }
            }
        })
    </script>
</body>

</html>